const glob = require("glob");
const path = require("path");

const entryFiles = glob.sync(path.join(__dirname,'..','..','**/errors/**/*.js'));
const errors = {};

entryFiles.forEach(file=> {
    const error = require(file);
    Object.assign(errors,error);
})

module.exports = errors;